EXE = upass
CFILES = main.c cuci.c hal_tick.c app_wifi.c user_uart.c app_socket_client.c at_cmd.c
CFILES+=$(wildcard ./easylogger/*.c)
OBJFILES=$(notdir $(CFILES:.c=.o))
INCLUDE = -I./ -I./easylogger/
LDFLAGS+=-L. -luci -lpthread -lrt
CFLAGS += -O0 -g3 -Wall

all : $(EXE)
	@echo $(CC)
	@echo $(CC)
	@echo $(CC)
	@echo $(CC)
	@echo $(CC)
	@echo $(CC)
	@echo $(CC)

$(EXE) : $(OBJFILES)
	$(CC) $^ $(LDFLAGS) -o $(EXE)

$(OBJFILES) : $(CFILES)
	$(CC) $(CFLAGS) -c $^ $(INCLUDE)
	
clean:
	rm *.o $(EXE)
